package c.e.a.a.f.s;

import android.util.SparseArray;
import c.e.a.a.b;
import java.util.EnumMap;

/* compiled from: PriorityMapping */
public final class a {
    public static SparseArray<b> a = new SparseArray();
    public static EnumMap<b, Integer> b;

    static {
        EnumMap enumMap = new EnumMap(b.class);
        b = enumMap;
        enumMap.put(b.DEFAULT, Integer.valueOf(0));
        b.put(b.VERY_LOW, Integer.valueOf(1));
        b.put(b.HIGHEST, Integer.valueOf(2));
        for (b bVar : b.keySet()) {
            a.append(((Integer) b.get(bVar)).intValue(), bVar);
        }
    }

    public static int a(b bVar) {
        Integer num = (Integer) b.get(bVar);
        if (num != null) {
            return num.intValue();
        }
        StringBuilder stringBuilder = new StringBuilder();
        stringBuilder.append("PriorityMapping is missing known Priority value ");
        stringBuilder.append(bVar);
        throw new IllegalStateException(stringBuilder.toString());
    }

    public static b b(int i) {
        b bVar = (b) a.get(i);
        if (bVar != null) {
            return bVar;
        }
        throw new IllegalArgumentException(c.b.a.a.a.A("Unknown Priority for value ", i));
    }
}
